package hotel.switchs.oversea.biz.mapper;

import hotel.base.oversea.repository.MyMapper;
import hotel.switchs.oversea.api.entity.SwitchCreateSubHotelLogEntity;
import org.apache.ibatis.annotations.Param;

/**
 * @Author lmf
 * @Date 2020/7/10 20:17
 **/
public interface SwitchCreateSubHotelLogMapper extends MyMapper<SwitchCreateSubHotelLogEntity> {

    /**
     * 根据省份id 和 星级 获取今日次数
     * @param provinceId
     * @param hotelStar
     * @return
     */
    int getNumByProvinceIdAndStar(@Param("provinceId") int provinceId, @Param("hotelStar") int hotelStar, @Param("day") int day);

    /**
     * 根据城市名称和星级获取今日次数
     * @param cityName
     * @param hotelStar
     * @return
     */
    int getNumByCityNameAndStar(@Param("cityName") String cityName, @Param("hotelStar") int hotelStar, @Param("day") int day);
}
